﻿<%@ Control Language="C#" Inherits="System.Web.Mvc.ViewUserControl<CourseSystem.Core.Entities.ExaminationInfo>" %>
<% using (Ajax.BeginForm("SectionTestEditUc", new { Model.Id }, new AjaxOptions { HttpMethod = "Post", UpdateTargetId = "editDiv", }))
   {%>
<% Html.RenderPartial("HighLightMsgUc"); %>
<fieldset>
    <div class="editor-label">
        <%: Html.LabelFor(model => model.Title) %>
    </div>
    <div class="editor-field">
        <%: Html.DisplayFor(model => model.Title) %>
        <%: Html.ValidationMessageFor(model => model.Title) %>
    </div>
    <% if (Model.Type == 1)
       { %>
    <div class="editor-label">
        <%: Html.LabelFor(model => model.EndTime) %>
    </div>
    <div class="editor-field">
        <%: Html.TextBoxFor(model => model.EndTime) %>
        <%: Html.ValidationMessageFor(model => model.EndTime) %>
    </div>
    <%}
       else if (Model.Type == 0)
       { %>
    <div class="editor-label">
        <%: Html.LabelFor(model => model.LimitTime) %>
    </div>
    <div class="editor-field">
        <%: Html.TextBoxFor(model => model.LimitTime) %>
        <%: Html.ValidationMessageFor(model => model.LimitTime) %>
    </div>
    <% } %>
    <p>
        <input type="submit" value="保存" />
    </p>
</fieldset>
<% } %>
<script type="text/javascript">
    $(function () {
        $("#EndTime").calendar();
    });
</script>
